from pydantic import BaseModel
from datetime import datetime

class MaterialCreate(BaseModel):
    user_id: int  # 需要传入用户 ID
    title: str
    file_path: str

class MaterialResponse(BaseModel):
    id: int
    title: str
    created_at: datetime
    

    class Config:
        from_attributes = True

class MaterialContent(BaseModel):
    material_id: int
    page_number: int
